- title @page.name
%div
  - for page in @page.ancestors.reverse
    = link_to h(page.name), page
    \&gt;

- unless @page.children.empty?
  %ul#submenu
    - for page in @page.children
      %li
        = link_to h(page.name), page

= simple_format(@page.content)
%p
  = link_to "Edit", edit_page_path(@page)
  |
  = link_to "Destroy", @page, :confirm => 'Are you sure?', :method => :delete
  |
  = link_to "View All", pages_path
